package cn.xie.ai.rag.knowledge.api;

import cn.xie.ai.rag.knowledge.api.response.Response;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * @author: xiaoxie
 * create: 2025-06-02 20:45
 * @BelongsProject: ai-rag-knowledge
 * @BelongsPackage: cn.xie.ai.rag.knowledge.api
 * description: rag接口
 */

public interface IRagService {

    /**
     * @description: 查询知识库
     * @author: xiaoxie
     * @date: 2025/6/2 下午8:47
     * @param: [tags]
     * @return: cn.xie.ai.rag.knowledge.api.response.Response<java.util.List<java.lang.String>>
     **/
    Response<List<String>> queryRagTagList();

    /**
     * @description: 上传知识库
     * @author: xiaoxie
     * @date: 2025/6/2 下午8:48
     * @param: [tags, files]
     * @return: cn.xie.ai.rag.knowledge.api.response.Response<java.lang.String>
     **/
    Response<String>  uploadRagTag(String tags,List<MultipartFile> files);

    /**
     * @description: 删除知识库标签
     * @author: xiaoxie
     * @date: 2025/6/2 下午8:48
     * @param: [tags]
     * @return: cn.xie.ai.rag.knowledge.api.response.Response<java.lang.Boolean>
     **/
    Response<Boolean> deleteRagTag(String tags);

    /**
     * @description: 上传git 仓库
     * @author: xiaoxie
     * @date: 2025/6/3 下午5:04
     * @param: [repoUrl, userName, token]
     * @return: cn.xie.ai.rag.knowledge.api.response.Response<java.lang.String>
     **/
    Response<String> analyzeGitRepository(String repoUrl, String userName, String token) throws Exception;

}
